package com.xiweicheng;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.netflix.feign.EnableFeignClients;
import org.springframework.cloud.netflix.hystrix.dashboard.EnableHystrixDashboard;
import org.springframework.cloud.netflix.zuul.EnableZuulProxy;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@SpringBootApplication
//@EnableEurekaClient
@EnableFeignClients
@EnableHystrixDashboard
@EnableZuulProxy
@RestController
public class CloudZuulHystrixRibbonApplication {

	@Autowired
	StoreClient storeClient;

	@RequestMapping("/")
	public Object home() {
		return storeClient.home();
	}

	public static void main(String[] args) {
		SpringApplication.run(CloudZuulHystrixRibbonApplication.class, args);
	}
}

